/**
 * @Author Stark
 * @Date 2022/2/15 11:56
 */
public class UsageOfStringBuilder {
    public static void main(String[] args) {
        StringBuilder str = new StringBuilder();
        str.append("hello ").append("world");
        fun(str);
        str.reverse();
        str.delete(1,2);
        str.reverse();
        str.insert(0,"nihao");
        String s = str.toString();
        System.out.println(s);
    }
    public static void fun(StringBuilder str){
        str.append("!!");
    }

}
